import request from '_c/utils/request'

/**
 * 推客-基本资料
 * @param username
 * @param password
 * @param captcha
 */
export function agentInfo() {
	return request({
		url: '/api/ag/my/center/info',
		method: 'GET'
	})
}

/**
 * 推客-角色
 */
export function agentRole() {
	return request({
		url: '/getInfo',
		method: 'GET'
	})
}

/**
 * 结算信息
 * agnetNo
 */
export function rateInfo(agnetNo) {
	return request({
		url: '/api/agent-rate/info/' + agnetNo,
		method: 'Get'
	})
}


/**
 * 结算卡
 * 
 */
export function addSettle(data) {
	return request({
		url: '/app/api/user/settle/add',
		method: 'POST',
		data
	})
}

//  删除他人结算卡
export function settlementDelOther(data) {
	return request({
		url: '/api/ag/my/center/settlement/delOther',
		method: 'post',
		data
	})
}

// 向本人结算手机号发送短信
export function sendNoMeSMS(query) {
	return request({
		url: '/api/ag/my/center/settle/sendSMS',
		method: 'get',
		params: query
	})
}
// 修改结算卡
export function editSettle(data) {
	return request({
		url: '/api/ag/my/center/settlement/edit',
		method: 'post',
		data
	})
}
// 新增他人结算卡
export function settlementAddOther(data) {
	return request({
		url: '/api/ag/my/center/settlement/addOther',
		method: 'post',
		data
	})
}

/**
 * 获取自己已开通政策列表
 * 
 */
export function myPolicyList() {
	return request({
		url: '/api/ag/agent/open/policy/info',
		method: 'Get'
	})
}

export function showAgentWallet(data) {
	return request({
		url: 'api/ag/agent/wallet/showAgentWallet',
		method: 'get',
		params: data
	})
}


// 提现前检查是否上传身份证图
export function verifyCardImg(data) {
	return request({
		url: '/api/ag/agent/withdraw/detail/verifyCardImg',
		method: 'get',
		params: data,
		noShowMsg: true
	})
}


export let uploadImageUrl = '/api/ag/agent/withdraw/detail/uploadCardImg'